# Contributor: mio <miyopan@e.email>
# Maintainer: mio <miyopan@e.email>
pkgname=barcode
pkgver=0.99
pkgrel=1
pkgdesc="Convert text strings to printed bars in various standards"
url="https://www.gnu.org/software/barcode/"
license="GPL-3.0-or-later"
arch="all !ppc64le" # Build error on ppc64le
source="https://ftp.gnu.org/gnu/barcode/barcode-$pkgver.tar.gz
	common.patch
	fix-format-error.patch
	"
options="!check" # No tests

prepare() {
	default_prepare

	update_config_sub
	update_config_guess
}

build() {
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr
	make
}

package() {
	make install DESTDIR="$pkgdir"

	rm -r "$pkgdir"/usr/share/info
}

sha512sums="
f500dbe7eaa657ed6879316835557533e0972c8740a8bb61bea46efdd4120827a3c412ca24fec6e1833395191521425dae272f10d8553a252896b363290118b1  barcode-0.99.tar.gz
a8d7d5721d28f7ae882b192db5ca69cd1b4e0a737f514e9ef096643800739fe99b015932a9b38b90194a175a5e541258f3e9252711ef23e978b909860fa050aa  common.patch
7c8696051d0c11226abfe90c231f5179cd8a8cd1de2ce54c17419323b72fdf9c96ca729d24367410ff3c738c3fe05a5338e38233822e702a55eb882971539a00  fix-format-error.patch
"
